1. Field of the Invention
The field of the invention is data processing, or, more specifically, methods, systems, and products for scaling address space utilization in a multi-threaded, multi-processor computer.
2. Description of Related Art
A ‘translation’ is a mapping from a segment in a process address space to a segment in virtual address space. Translations are cached for high-speed access in Segment Lookaside Buffers (‘SLBs’). Each processor in a multi-processor computer system typically has an SLB for use in translating memory references from process address space to virtual address space.
It is common for one thread of a multi-threaded process or application to remove addressability to a particular area of memory for the whole process. One thread will attach a region of virtual memory to the process address space, read and/or write, and then that thread or another thread will detach the region. On a multiprocessor system this presents a problem, because another thread of the same process currently running on some other processor at the time of the detachment may have a local mapping in its SLB to that region of virtual memory. The translation in the detaching processor's SLB and its corresponding global translation in a main segment map or segment table maintained by the operating system are both removed by the detachment, but the translation in the other processor's SLB is not removed by the detachment. So the thread running on that other processor can still attempt to reference this now detached area of memory. In effect, the translation in the other processor's SLB has become invalid or ‘stale’ without the other processor's being informed of the invalidity. Processing errors will result if this other processor references a memory segment mapped through such a stale translation.
An existing solution for this problem is to send a message to every other processor on the system before completing a cross-memory detachment. Such a message tells each processor on the system to reset its SLB and send a message back to the detaching processor when it has finished. When all processors have acknowledged that they have reset their SLBs, the detachment is allowed to complete. Now no threads can have stale translations to the detached virtual memory region.
The problem with this solution is that it has a substantial performance impact, especially on systems with many processors. If one processor does a detach, every other processor, even if it is running a totally unrelated job, must stop what it is doing, reset its SLB, and respond. When the other processors resume operation, they must reload their SLBs with any valid translations that were wiped out, translations that are still represented by entries in the operating system's segment table for the process. This problem only gets worse as the number of processors increases, because the chance that any one processor is doing a detachment at any given time increases with the number of processors. There is an ongoing need therefore, for improvement in the administration of address space in multi-threaded, multi-processor computer systems.